<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>举办比赛</title>
<link rel="stylesheet" type="text/css"
	href="/crowd-sourcing/static/bootstart/css/bootstrap.min.css" />
	<style type="text/css">
	body{
	padding:0;
	margin: 0;
	 background-color: cornflowerblue;
	}
	.container{
	background-image: url(/crowd-sourcing/img/bg.png);
	}
	h1{
	color:red;
	}
	.col-lg-12{
	background-image: url(/crowd-sourcing/img/301235.jpg);
	}
	.col-lg-6{
	text-align: center;
	}
	</style>
</head>
<body>
<div class="container">
<div class="row">
<div class="col-lg-12">
<h1>举办比赛</h1>
</div>

</div>
<div class="row">
<div class="col-lg-6"><h3>比赛名称:</h3><input type="text"></div>
<div class="col-lg-6"><button type="button" class="btn btn-primary" onclick="ti()">提交比赛</button>

                      <button type="button" class="btn btn-primary" onclick="window.location.href='/crowd-sourcing/hone.jsp'">返回上一页</button>
</div>
</div>
<div class="row">
<div class="col-lg-6"></div>
<div class="col-lg-6"><h1>注意事项</h1></div>
</div>
<div class="row">
<div class="col-lg-6"><h3>比赛奖金:</h3><input type="text"></div>
<div class="col-lg-6"><h4>1.比赛秉承公平，公正，公开</h4></div>
</div>
<div class="row">
<div class="col-lg-6"><h3>大赛宗旨:</h3><input type="text" style="height: 60px;width="100px""></div>
<div class="col-lg-6"><h4>2.如果在大赛期间发生一系列安全事故，由赛事方全权负责</h4></div>
</div>
<div class="row">
<div class="col-lg-6"><h3>大赛形式:</h3><input type="text" style="height: 60px;width="100px""></div>
<div class="col-lg-6"><h4>3.赛事应该积极向上，如有危害民族，国家，反动思想会立即撤销大赛</h4></div>
</div>

<div class="row">
<div class="col-lg-6"><h3>大赛规则:</h3><input type="text" style="height: 60px;width="100px""></div>
<div class="col-lg-6"><h4></h4></div>
</div>

</div>

<script src="/crowd-sourcing/static/js/jquery-3.4.1.js"></script>
<script type="text/javascript">
function ti(){
	var name=$(".container input");
	var s={
			"name":name[0].value,
			"bonus":name[1].value,
			"purpose":name[2].value,
			"form":name[3].value,
			"rule":name[4].value
			
	}
	
	$.ajax({
		type:"post",
	    url:"gou",
	    data:{
	    	"opo":"ad",
	    	"da":JSON.stringify(s)
	    },
	   
	success:function(data){
		if (data == "true") {
			alert("提交成功");
			window.location.href="hone.jsp"
			
			sessionStorage.setItem("list",name);
		} else {
			alert("提交失败");
		}
		
	}
	})
	
}

</script>
</body>
</html>